//
//  AIMineYoiuHuiQuanCell.m
//  ZJCLoveBee
//
//  Created by 朱建超 on 16/12/23.
//  Copyright © 2016年 itHeiMa. All rights reserved.
//

#import "AIMineYoiuHuiQuanCell.h"

@interface AIMineYoiuHuiQuanCell ()

@property (weak, nonatomic) IBOutlet UILabel *valueLabel;

@property (weak, nonatomic) IBOutlet UILabel *nameLabel;

@property (weak, nonatomic) IBOutlet UILabel *timeLabel;

@property (weak, nonatomic) IBOutlet UILabel *descLabel;

@property (weak, nonatomic) IBOutlet UIImageView *iocnImage;

@end

@implementation AIMineYoiuHuiQuanCell

- (void)awakeFromNib {
    [super awakeFromNib];
    
    self.iocnImage.layer.cornerRadius = 26;
    self.iocnImage.layer.masksToBounds = YES;
    
}

-(void)setYouHuiQuanModel:(AIMineYouHuiQuanModel *)youHuiQuanModel{

    _youHuiQuanModel = youHuiQuanModel;
    
    self.valueLabel.text = youHuiQuanModel.value;
    self.nameLabel.text = youHuiQuanModel.name;
    
    NSString *str1 = @"有效期：";
    NSString *startTime_String = youHuiQuanModel.start_time;
    NSString *str3 = @"到";
    NSString *endTime_String = youHuiQuanModel.end_time;
    
    NSString *firstString = [str1 stringByAppendingString:startTime_String];
    NSString *secondString = [firstString stringByAppendingString:str3];
    NSString *resultString = [secondString stringByAppendingString:endTime_String];
    self.timeLabel.text = resultString;
    self.descLabel.text = youHuiQuanModel.desc;

}

@end
